package com.zsrt.devbase.common.utils;

import org.springframework.ui.ModelMap;

/** 
 * @author leixin  
 * @Email leixin821792669@gmail.com
 * @date 2018年7月8日 下午4:57:16
 * @version 1.0
 */
public class ResponseVO extends ModelMap{
	private static final long serialVersionUID = 2692052034897353250L;

	public ResponseVO() {
		this(MsgConstantConfig.ResponseState.SUCCESS.getCode(), MsgConstantConfig.ResponseState.SUCCESS.getMsg());
	}
	
	public ResponseVO(String responseCode) {
		this(responseCode,MsgConstantConfig.ResponseState.SUCCESS.getMsg());
	}
	
	public ResponseVO(String responseCode,String responseMsg) {
		this.setResponseCode(responseCode);
		this.setResponseMsg(responseMsg);
	}
	
	public String getResponseCode() {
		return (String)this.get("responseCode");
	}
	public ResponseVO setResponseCode(String responseCode) {
		this.put("responseCode", responseCode);
		return this;
	}
	
	public String getResponseMsg() {
		return (String) this.get("responseMsg");
	}
	
	public ResponseVO setResponseMsg(String responseMsg) {
		this.put("responseMsg", responseMsg);
		return this;
	}
	
	public ResponseVO setData(Object data) {
		this.put("data", data);
		return this;
	}
	
	public Object getData() {
		return this.get("data");
	}

}
